import { tokenize } from './js/tokenize'
import { parse } from './js/parse'
import { transform } from './js/transform'
import { generate } from './js/generate'

const str = `
$ib inline-block
$borderColor lightGreen
div
  p
    border 1px solid $borderColor
  color darkkhaki
  .a-b
    background-color lightyellow
    [data]
      padding 15px
      font-size 12px
.d-ib
  display $ib
`;

const tokens = tokenize(str);
console.log(tokens);
const ast = parse(tokens)
console.log(ast)
const code = transform(ast)
console.log(code)
const endCode = generate(code)
console.log(endCode)


// 最后将我这个endCode写入css 就可以了